power: as3722: fix ldo_get/set_enable for ldo index bigger than 7
authorMarcel Ziswiler <[email protected]>
Tue, 8 May 2018 15:34:08 +0000 (17:34 +0200)
committerTom Warren <[email protected]>
Thu, 10 May 2018 23:34:20 +0000 (16:34 -0700)
commit4616e33b6a01b2f12c422d0d27afbbbbee2985e8
treee9026afe9cc5ee3d9758ac513ee3df2d9a34648c
parentc0cb8c8e8656639ebeeaa0d98a1f3c0807f590b3
power: as3722: fix ldo_get/set_enable for ldo index bigger than 7

Fix ldo_get_enable() and ldo_set_enable() functions for LDOs with an
index > 7. Turns out there are actually two separate AS3722_LDO_CONTROL
registers AS3722_LDO_CONTROL0 and AS3722_LDO_CONTROL1. Actually make use
of both. While at it also actually use the enable parameter of the
ldo_set_enable() function which now truly allows disabling as opposed to
only enabling LDOs.

Signed-off-by: Marcel Ziswiler <[email protected]>
Signed-off-by: Tom Warren <[email protected]>
drivers/power/regulator/as3722_regulator.c
include/power/as3722.h